package com.uaroadshow.finale.service;

import java.util.Map;

import com.uaroadshow.entity.trade.Order;
import com.uaroadshow.entity.trade.PaymentRequest;
import com.uaroadshow.entity.user.User;
import com.uaroadshow.finale.entity.Shopping;

/**
 *
 * @author Ark
 *
 */
public interface OrderService extends DataService<Order> {

    /**
     * @param shopping
     * @param user
     * @return
     */
    public Order create(Shopping shopping, User user);
    
    /**
     * @param orderId
     * @param user
     * @param remoteIp
     */
    public Map<String, Object> pay(Long orderId, User user, String remoteIp);

    /**
     * @param paymentRequest
     * @param orderCode
     * @param payCode
     * @param payTime
     */
    public Order paid(PaymentRequest paymentRequest, String orderCode, String payCode, String payTime);
    
}
